<template>
  <div class="searchBtns">
    <auth-button :auth="managePerms.menu.view" @click="$emit('query')" type="info">
      <i class="iconfont icon-chazhao"></i>
      {{ $t('inquiry') }}
    </auth-button>
    <auth-button :auth="managePerms.menu.add" type="primary" @click="clickAdd">
      <i class="iconfont icon-xinjian"></i>
      菜单
    </auth-button>
    <!--<auth-button :auth="softwarePerms.partsSoftware.add" @click="clickAdd">-->
    <!--<i class="iconfont icon-xinjian"></i>-->
    <!--菜单-->
    <!--</auth-button>-->
  </div>
</template>

<script>
  import { managePerms } from '@/config/permission/index'
  import AuthButton from '@/components/AuthButton'
export default {
  name: 'search',
  data: ()=>{
    return {
      managePerms
    }
  },
  methods: {
    clickAdd () {
      this.$emit('clickAdd', { id: undefined, parentId: 'allMenusId', chooseType: 'new' })
    }
  },
  components:{
    AuthButton
  }
}
</script>

<style lang="less" scoped>
</style>
